﻿using System;
using System.Collections.Generic;
using System.Data.Entity.ModelConfiguration;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Himall.Entity.Config
{
   public class FloorProductInfoConfig : EntityTypeConfiguration<FloorProductInfo>
    {
        public FloorProductInfoConfig()
        {
            ToTable("Himall_FloorProducts");
        
            HasRequired(x => x.HomeFloorInfo).WithMany(x => x.FloorProductInfo).HasForeignKey(x => x.FloorId);
            HasRequired(x => x.ProductInfo).WithMany(x => x.Himall_FloorProducts).HasForeignKey(x => x.ProductId);
        }
    }
}
